package latihan.action;

import java.util.logging.Logger;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts2.ServletActionContext;

import com.opensymphony.xwork2.ActionSupport;

public class BaseController extends ActionSupport {
	/**
	 * 
	 */
	private static final long serialVersionUID = 1350711202011075585L;

	public Logger log = Logger.getLogger(BaseController.class.getName());
	
	HttpServletRequest request = ServletActionContext.getRequest();
	protected String url = request.getServletPath();
	protected String url1 = request.getScheme();
	protected String url2 = request.getServerName();
	protected int url3 = request.getServerPort();
	protected String link = url1+"/"+url2+":"+url3;
	
	public BaseController() {
		super();
		
		log.info("url = "+url);
		log.info("url1 = "+url1);
		log.info("url2 = "+url2);
		log.info("url3 = "+url3);
		log.info("link = "+link);
	}
	
	
}
